package com.yuyou.hxyy.service.api.mapper;

import com.yuyou.hxyy.service.api.entity.UserWordRepo;
import com.yuyou.hxyy.service.api.vo.resp.UserWordRepoVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface UserWordRepoMapper {
    int deleteByPrimaryKey(Long userWordRepoId);

    int insert(UserWordRepo record);

    UserWordRepo selectByPrimaryKey(Long userWordRepoId);

    int updateByPrimaryKeySelective(UserWordRepo record);

    List<UserWordRepoVo> findLearningList(@Param(value = "userId") Long userId , @Param(value = "status") Integer status);

    void deleteByRepoIds(@Param(value = "repoIds") String repoIds);

    List<Long> getIdByWordUtil(@Param(value = "utilIds") String utilIds , @Param(value = "ids") List<Long> ids);

    UserWordRepo getByRepoUserId(@Param(value = "wordRepoId")Long wordRepoId, @Param(value = "userId")Long userId);

    List<Long> getNotUpdatedUserRepo(@Param(value = "repoId") Long repoId);

    void updateStatusByrepoIdUserIds(@Param(value = "repoId") Long repoId , @Param(value = "userIds") List<Long> userIds);
}